package cn.wolfcode.dubbo.user.userdata;

import cn.wolfcode.dubbo.User.domain.User;

import java.util.HashMap;
import java.util.Map;

//模拟数据库
public class UserData {
    private static Map<Long, User> datas = new HashMap<>();

    static {
        datas.put(1L, new User(1L, "张翼德"));
        datas.put(2L, new User(2L, "马孟起"));
    }

    public static User get(Long id) {
        return datas.get(id);
    }
}
